﻿IF EXISTS (SELECT * FROM sysobjects WHERE type = 'P' AND name = 'usp_UPDMS_CFG_SETTING_MGT_Get_Search_Count')
	BEGIN
		DROP Procedure usp_UPDMS_CFG_SETTING_MGT_Get_Search_Count
	END
GO

SET ANSI_NULLS ON
SET QUOTED_IDENTIFIER ON
GO
/******************************************************************************
**	Name : usp_UPDMS_CFG_SETTING_MGT_Get_Search_Count
**	Desc : 설정관리의 검색결과수를 카운트한다.
**	Test Exec Query : Exec usp_UPDMS_CFG_SETTING_MGT_Get_Search_Count '','',''
**	Called by : Cfg_Dac_UPDMS_CFG_SETTING_MGT.cs
**	Program ID : Cfg1011m
**	Auth : 송시명
**	Date : 2013-05-13
*******************************************************************************
**	Change History
*******************************************************************************
**	Date:		Author:		Description:
**	--------	--------	---------------------------------------
**	
*******************************************************************************/
CREATE PROC [dbo].[usp_UPDMS_CFG_SETTING_MGT_Get_Search_Count]
@ls_setting_nm nvarchar(200),
@ls_setting_cd nvarchar(20),
@ls_setting_value nvarchar(200)
AS
SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED
SET NOCOUNT ON

SELECT COUNT(Seq) AS Search_Count
  FROM UPDMS_CFG_SETTING_MGT WITH(NOLOCK)
 WHERE Setting_Nm LIKE '%' + @ls_setting_nm + '%'
   AND Setting_Cd LIKE '%' + @ls_setting_cd + '%'
   AND Setting_Value LIKE '%' + @ls_setting_value + '%'

GO